package harvard.cscie160.hw7.project;
import java.rmi.Naming;


/**
 * 
 * @author M Bret Blackford
 *
 */
public class BankServer {

	public static void main(String[] args) {
		
		String serviceName = "//localhost/bank";

		try {
			BankImpl obj = new BankImpl();
			Naming.rebind(serviceName, obj);
			
			System.out.println();
			System.out.println();
			System.out.println(DateUtils.now() + " BankImpl bound in registry ");
			System.out.println(DateUtils.now() + " BankImpl bound as " + serviceName);
		} catch (Exception e) {
			System.out.println(DateUtils.now() + " Bank error: " + e.getMessage());
			e.printStackTrace();
		}
	}
}
